	<!-- Modal edit user -->
<%@ page language="java" contentType="text/html; charset=utf-8"
	pageEncoding="utf-8"%>
	<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
	<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
	<div class="modal fade" id="modalUpdate" tabindex="-1" role="dialog"
		aria-labelledby="myModalLabel" aria-hidden="true">
		<div class="modal-dialog">
			<div class="modal-content">
				<div class="modal-header">
					<button type="button" class="close" data-dismiss="modal">
						<span aria-hidden="true">&times;</span><span class="sr-only">Đóng</span>
					</button>
					<h4 class="modal-title" id="myModalLabel">Cập nhật thông tin người dùng</h4>
				</div>
				<form action="update">
					<input type="hidden" id="userIdeee" name="userId">
					<div class="panel-body">
						<div class="mb10 input-group">
							<span class="input-group-addon">Họ tên&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;
								&nbsp; &nbsp; &nbsp; &nbsp;</span> <input type="text" name='fullname'
								class="form-control" placeholder="Fullname" id="updateFullname">
						</div>
						<div class="mb10 input-group">
							<span class="input-group-addon">Tên đăng nhập
							&nbsp; &nbsp; &nbsp;&nbsp;&nbsp;</span> <input type="text" name='username'
								class="form-control" placeholder="Username" id="usernameeee" autocomplete="off"
								required>
						</div>
						<br>
						<div class="mb10 input-group">
							<span class="input-group-addon">Mật khẩu&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;
							&nbsp; &nbsp; &nbsp; &nbsp;</span> <input type="password"
								id="p1" name='password' class="form-control"
								placeholder="Password">
						</div>
						<br>
						<div class="mb10 input-group">
							<span class="input-group-addon">Xác nhận mật khẩu</span> <input
								type="password" class="form-control" id="p2"
								onfocus="validatePass(document.getElementById('p1'), this);"
								oninput="validatePass(document.getElementById('p1'), this);"								
								placeholder="Confirm password" name="confirmpassword">
						</div>
						<br>
						<div class="mb10 input-group">
							<span class="input-group-addon">Email&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
							&nbsp; &nbsp; &nbsp;</span> <input type="text"
								name='email' class="form-control" placeholder="E-mail"
								id="emaileee" required>
						</div>
						<br>
						<div class="input-group">
							<span class="input-group-addon">Quyền &nbsp; &nbsp; &nbsp;&nbsp;
							&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;</span> <select
								class="form-control" name='roleId' id="roleIdeee">
								<option value="1">Nhân viên bán hàng</option>
								<option value="3">Chủ cửa hàng</option>
							</select>
						</div>
						<br>
						<div class="input-group" style="margin-left: 45%">
						<button type="Submit" class="btn btn-success btn-square">Lưu</button>
								<form action="delete">
 									<input type="hidden" name="userId" id="deleteuser" value= ""/>
									<button type="button" onclick="deleteUser()" class="btn btn-danger btn-square">Xóa</button>
								</form>
						</div>
					</div>
				</form>
			</div>
		</div>
	</div>
<script>
function validatePass(p1, p2) {
	
	    if (p1.value != p2.value || p1.value == '' || p2.value == '') {
	
	        p2.setCustomValidity('Confirm Password incorrect');
	
	    } else {
	
	        p2.setCustomValidity('');
	
	    }
	
	}

</script>